/*
* @overview: 主题-装饰器
* @Author: wgf 
* @Date: 2024-04-22 13:07:44 
*/

part of 'index.dart';

extension AppDecorations on CustomTheme {
  BoxDecoration get button1 {
    return BoxDecoration(
      borderRadius: BorderRadius.circular(8.sp),
      color: colors.buttonBackground1,
    );
  }

  BoxDecoration get button2 {
    return BoxDecoration(
      border: Border.all(color: colors.border3),
      borderRadius: BorderRadius.circular(100.sp),
    );
  }

  BoxDecoration get button3 {
    return BoxDecoration(
      color: colors.buttonBackground1,
      borderRadius: BorderRadius.circular(100.sp),
    );
  }

  BoxDecoration get topBorder1 {
    return BoxDecoration(
      border: Border(
        top: BorderSide(
          width: 0.5,
          color: colors.border1,
        ),
      ),
    );
  }

  BoxDecoration get bottomBorder1 {
    return BoxDecoration(
      border: Border(
        bottom: BorderSide(
          width: 0.5,
          color: colors.border1,
        ),
      ),
    );
  }

  BoxDecoration get bg1Radius16 {
    return BoxDecoration(
      color: AppThemes.of().colors.background1,
      borderRadius: BorderRadius.circular(16.sp),
    );
  }

  BoxDecoration get gradient {
    return const BoxDecoration(
      gradient: LinearGradient(
        begin: Alignment.centerLeft,
        end: Alignment.centerRight,
        colors: [
          Color(0xFFF80002),
          Color(0xFFFF2E2F),
        ],
      ),
    );
  }

  BoxDecoration get border2Radius4 {
    return BoxDecoration(
      border: Border.all(color: colors.border2, width: 0.5),
      borderRadius: BorderRadius.circular(4.sp),
    );
  }
}
